package com.codeyang.feign;

import com.codeyang.domain.Order;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 描述: describe
 *
 * @author CodeYang_Site
 * @version 2021/6/2 19:22
 */
@FeignClient(value = "order-service")
public interface PayOrderFeign {

    /**
     * 远程调用 - 根据订单号得到订单信息
     *
     * @param orderNumber
     * @return
     */
    @GetMapping("p/myOrder/getOrderByOrderNumber")
    Order getOrderByOrderNumber(@RequestParam String orderNumber);


    /**
     * 修改订单状态
     *
     * @param orderNum
     */
    @PostMapping("p/myOrder/changeOrderStatus")
    void changeOrderStatus(@RequestParam String orderNum);



}
